// *Author：jxx
// *Contact：283591387@qq.com
// *代码由框架生成,任何更改都可能导致被代码生成器覆盖
export default function(){
    const table = {
        key: 'PeriodMaterialAccountId',
                editTable:true ,
        footer: "Foots",
        cnName: '生产原材料核算期初表',
        name: 'PeriodMaterialAccount',
        newTabEdit: false,
        url: "/PeriodMaterialAccount/",
        sortName: "PeriodMaterialAccountId"
    };
    const tableName = table.name;
    const tableCNName = table.cnName;
    const newTabEdit = false;
    const key = table.key;
    const editFormFields = {"StartPeriodQty":"","StartPeriodAmount":""};
    const editFormOptions = [[{"title":"期初领料数量","required":true,"field":"StartPeriodQty","type":"decimal"},
                               {"title":"期初领用金额","required":true,"field":"StartPeriodAmount","type":"decimal"}]];
    const searchFormFields = {"PeriodYear":"","PeriodMonth":""};
    const searchFormOptions = [[{"dataKey":"会计年度","data":[],"title":"会计年度","field":"PeriodYear","type":"select"},{"dataKey":"会计期间月份","data":[],"title":"会计期间","field":"PeriodMonth","type":"select"}]];
    const columns = [{field:'PeriodMaterialAccountId',title:'原材料核算期初标识',type:'int',width:110,hidden:true,require:true,align:'left'},
                       {field:'ProductTaskId',title:'生产任务单编号',type:'int',bind:{ key:'生产任务单编号',data:[]},width:110,require:true,align:'left'},
                       {field:'PeriodYear',title:'会计年度',type:'int',bind:{ key:'会计年度',data:[]},width:80,require:true,align:'left'},
                       {field:'PeriodMonth',title:'会计期间',type:'int',bind:{ key:'会计期间月份',data:[]},width:80,require:true,align:'left'},
                       {field:'MaterialId',title:'物料标识',type:'int',width:110,require:true,align:'left'},
                       {field:'MaterialNo',title:'物料编码',type:'string',width:110,readonly:true,require:true,align:'left'},
                       {field:'MaterialName',title:'物料名称',type:'string',width:110,readonly:true,require:true,align:'left'},
                       {field:'Spec',title:'规格型号',type:'string',width:110,readonly:true,align:'left'},
                       {field:'IsCriticalParts',title:'是否关键件',type:'int',bind:{ key:'是否',data:[]},width:80,require:true,align:'left'},
                       {field:'StartPeriodQty',title:'期初领料数量',type:'decimal',width:110,edit:{type:'decimal'},require:true,align:'left'},
                       {field:'StartPeriodAmount',title:'期初领用金额',type:'decimal',width:110,edit:{type:'decimal'},require:true,align:'left'},
                       {field:'UnitQty',title:'单位用量',type:'decimal',width:110,readonly:true,require:true,align:'left'},
                       {field:'IsEnabled',title:'启用',type:'int',bind:{ key:'是否',data:[]},width:80,require:true,align:'left'}];
    const detail ={columns:[]};
    const details = [];

    return {
        table,
        key,
        tableName,
        tableCNName,
        newTabEdit,
        editFormFields,
        editFormOptions,
        searchFormFields,
        searchFormOptions,
        columns,
        detail,
        details
    };
}